import request from '/@/utils/request'
import {prefix} from '/@/api/oa'

export function getExportUrl() {
    return prefix + 'office/position/exportExcel'
}

export function createPosition(data: object) {
    return request({
        url: prefix + '/officePosition/create',
        method: 'post',
        data
    })
}

export function editPosition(data: object) {
    return request({
        url: prefix + '/officePosition/edit',
        method: 'post',
        data
    })
}

export function deletePosition(data: object) {
    return request({
        url: prefix + '/officePosition/delete',
        method: 'post',
        data
    })
}

export function getPositionPage(params: object) {
    return request({
        url: prefix + '/officePosition/getPage',
        method: 'get',
        params
    })
}

export function getPositionSelector() {
    return request({
        url: prefix + '/officePosition/getSelectorData',
        method: 'get'
    })
}
